﻿<UserControl x:Name="userControl"
    x:Class="EString.Controls.Marquee.MarqueeDragBox"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:EString.Controls.Marquee"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d"
    d:DesignHeight="36"
    d:DesignWidth="38" Width="Auto" Height="Auto" ManipulationMode="All">
	<UserControl.Projection>
		<PlaneProjection/>
	</UserControl.Projection>
    
    <Border x:Name="border" BorderThickness="2" BorderBrush="#3FFF0000" Background="#2AE22525">
    	<VisualStateManager.VisualStateGroups>
    		<VisualStateGroup x:Name="VisualStateGroup">
    			<VisualStateGroup.Transitions>
    				<VisualTransition GeneratedDuration="0:0:0.3">
    					<VisualTransition.GeneratedEasingFunction>
    						<CubicEase/>
    					</VisualTransition.GeneratedEasingFunction>
    				</VisualTransition>
    				<VisualTransition GeneratedDuration="0:0:0.3" To="Manipulating">
    					<VisualTransition.GeneratedEasingFunction>
    						<CubicEase EasingMode="EaseIn"/>
    					</VisualTransition.GeneratedEasingFunction>
    				</VisualTransition>
    				<VisualTransition GeneratedDuration="0:0:0.7" To="MouseOver"/>
    				<VisualTransition From="Hidden" GeneratedDuration="0:0:0.5">
    					<VisualTransition.GeneratedEasingFunction>
    						<CircleEase/>
    					</VisualTransition.GeneratedEasingFunction>
    				</VisualTransition>
    				<VisualTransition GeneratedDuration="0:0:0.6" To="Hidden">
    					<VisualTransition.GeneratedEasingFunction>
    						<CircleEase EasingMode="EaseIn"/>
    					</VisualTransition.GeneratedEasingFunction>
    				</VisualTransition>
    			</VisualStateGroup.Transitions>
    			<VisualState x:Name="Manipulating">
    				<Storyboard>
    					<ColorAnimation Duration="0" To="#2BE22525" Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)" Storyboard.TargetName="border" d:IsOptimized="True"/>
    					<ColorAnimation Duration="0" To="#CCFF0000" Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Color)" Storyboard.TargetName="border" d:IsOptimized="True"/>
    				</Storyboard>
    			</VisualState>
    			<VisualState x:Name="Normal"/>
    			<VisualState x:Name="MouseOver">
    				<Storyboard>
    					<ColorAnimation Duration="0" To="#2BE22525" Storyboard.TargetProperty="(Border.Background).(SolidColorBrush.Color)" Storyboard.TargetName="border" d:IsOptimized="True"/>
    					<ColorAnimation Duration="0" To="#CCFF0000" Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Color)" Storyboard.TargetName="border" d:IsOptimized="True"/>
    					<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="rectangle">
    						<EasingDoubleKeyFrame KeyTime="0:0:0.3" Value="0"/>
    						<EasingDoubleKeyFrame KeyTime="0:0:0.7" Value="0"/>
    					</DoubleAnimationUsingKeyFrames>
    					<DoubleAnimation Duration="0:0:0.7" To="3" Storyboard.TargetProperty="(UIElement.RenderTransform).(CompositeTransform.ScaleX)" Storyboard.TargetName="rectangle" d:IsOptimized="True"/>
    					<DoubleAnimation Duration="0:0:0.7" To="3" Storyboard.TargetProperty="(UIElement.RenderTransform).(CompositeTransform.ScaleY)" Storyboard.TargetName="rectangle" d:IsOptimized="True"/>
    					<DoubleAnimation Duration="0" To="-1" Storyboard.TargetProperty="(UIElement.Projection).(PlaneProjection.CenterOfRotationY)" Storyboard.TargetName="userControl" d:IsOptimized="True"/>
    				</Storyboard>
    			</VisualState>
    			<VisualState x:Name="Hidden">
    				<Storyboard>
    					<DoubleAnimation Duration="0" To="-84" Storyboard.TargetProperty="(UIElement.Projection).(PlaneProjection.RotationX)" Storyboard.TargetName="userControl" d:IsOptimized="True"/>
    					<DoubleAnimation Duration="0" To="-2.1" Storyboard.TargetProperty="(UIElement.Projection).(PlaneProjection.CenterOfRotationY)" Storyboard.TargetName="userControl" d:IsOptimized="True"/>
    					<DoubleAnimation Duration="0" To="0" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="userControl" d:IsOptimized="True"/>
    					<ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.IsHitTestVisible)" Storyboard.TargetName="userControl">
    						<DiscreteObjectKeyFrame KeyTime="0">
    							<DiscreteObjectKeyFrame.Value>
    								<x:Boolean>False</x:Boolean>
    							</DiscreteObjectKeyFrame.Value>
    						</DiscreteObjectKeyFrame>
    					</ObjectAnimationUsingKeyFrames>
    				</Storyboard>
    			</VisualState>
    		</VisualStateGroup>
    	</VisualStateManager.VisualStateGroups>
    
		<Grid x:ConnectionId='1' RenderTransformOrigin="0.462999999523163,-1.41499996185303"                                   >
			<Rectangle x:ConnectionId='2' x:Name="rectangle" HorizontalAlignment="Center" Height="26" VerticalAlignment="Center" Width="26" Stroke="Red" RenderTransformOrigin="0.5,0.5" IsTapEnabled="False" IsRightTapEnabled="False" IsHoldingEnabled="False" IsHitTestVisible="False"                                      >
				<Rectangle.RenderTransform>
					<CompositeTransform ScaleX="0" ScaleY="0"/>
				</Rectangle.RenderTransform>
			</Rectangle>
			<TextBlock x:Name="txtManip" HorizontalAlignment="Left" Opacity="0" Text="TRACKING..." VerticalAlignment="Top" FontFamily="Simplified Arabic" FontSize="18.667" FontStretch="Expanded" Margin="-22,-34,-90,0" Width="153" FontStyle="Italic" Foreground="Red" IsHitTestVisible="False" IsTapEnabled="False" IsRightTapEnabled="False" IsHoldingEnabled="False" IsDoubleTapEnabled="False"/>
		</Grid>
	</Border>
</UserControl>

